package com.nsoft.server.register.beans;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import java.util.Set;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.OneToMany;
import javax.persistence.Table;

import com.nsoft.server.master.beans.AccountMaster;
import com.nsoft.server.master.beans.PartyMaster;
import com.nsoft.server.master.beans.UserMaster;

@Entity
@Table(name="billing_header")
public class BillingHeader implements Serializable {
	@Id
	@Column(name="bill_num_id")
	private int billNumId;

	@Column(name="bill_num_no")
	private int billNumNo;

	@Column(name="bill_date_date")
	private Date billDateDate;

	@ManyToOne
	@JoinColumn(name="bill_num_partyA")
	private PartyMaster partyMaster;
	
	/*@Column(name="bill_num_partyA")
	private int billNumPartya;*/
	
	@ManyToOne
	@JoinColumn(name="bill_num_accid")
	private AccountMaster accountMaster;
	
	
	@ManyToOne
	@JoinColumn(name="bill_date_updatedby")
	private UserMaster userMaster;
/*
	@Column(name="bill_num_accid")
	private int billNumAccid;*/

	public PartyMaster getPartyMaster() {
		return partyMaster;
	}

	public void setPartyMaster(PartyMaster partyMaster) {
		this.partyMaster = partyMaster;
	}

	public AccountMaster getAccountMaster() {
		return accountMaster;
	}

	public void setAccountMaster(AccountMaster accountMaster) {
		this.accountMaster = accountMaster;
	}

	public UserMaster getUserMaster() {
		return userMaster;
	}

	public void setUserMaster(UserMaster userMaster) {
		this.userMaster = userMaster;
	}

	@Column(name="bill_char_description")
	private String billCharDescription;

	@Column(name="bill_cur_totalAmt")
	private BigDecimal billCurTotalamt;

	@Column(name="bill_char_general1")
	private String billCharGeneral1;

	@Column(name="bill_char_general2")
	private String billCharGeneral2;

	@Column(name="bill_char_general3")
	private String billCharGeneral3;

	@Column(name="bill_char_general4")
	private String billCharGeneral4;

	@Column(name="bill_char_general5")
	private String billCharGeneral5;

	@Column(name="bill_char_updatedby")
	private int billCharUpdatedby;

	
	
	/*@Column(name="bill_date_updatedby")
	private Date billDateUpdatedby;*/

	@OneToMany(mappedBy="bidNumBillid")
	private Set<BillingDetail> billingDetailCollection;

	@OneToMany(mappedBy="bifNumBillid")
	private Set<BillingFooter> billingFooterCollection;

	private static final long serialVersionUID = 1L;

	public BillingHeader() {
		super();
	}

	public int getBillNumId() {
		return this.billNumId;
	}

	public void setBillNumId(int billNumId) {
		this.billNumId = billNumId;
	}

	public int getBillNumNo() {
		return this.billNumNo;
	}

	public void setBillNumNo(int billNumNo) {
		this.billNumNo = billNumNo;
	}

	public Date getBillDateDate() {
		return this.billDateDate;
	}

	public void setBillDateDate(Date billDateDate) {
		this.billDateDate = billDateDate;
	}

	public String getBillCharDescription() {
		return this.billCharDescription;
	}

	public void setBillCharDescription(String billCharDescription) {
		this.billCharDescription = billCharDescription;
	}

	public BigDecimal getBillCurTotalamt() {
		return this.billCurTotalamt;
	}

	public void setBillCurTotalamt(BigDecimal billCurTotalamt) {
		this.billCurTotalamt = billCurTotalamt;
	}

	public String getBillCharGeneral1() {
		return this.billCharGeneral1;
	}

	public void setBillCharGeneral1(String billCharGeneral1) {
		this.billCharGeneral1 = billCharGeneral1;
	}

	public String getBillCharGeneral2() {
		return this.billCharGeneral2;
	}

	public void setBillCharGeneral2(String billCharGeneral2) {
		this.billCharGeneral2 = billCharGeneral2;
	}

	public String getBillCharGeneral3() {
		return this.billCharGeneral3;
	}

	public void setBillCharGeneral3(String billCharGeneral3) {
		this.billCharGeneral3 = billCharGeneral3;
	}

	public String getBillCharGeneral4() {
		return this.billCharGeneral4;
	}

	public void setBillCharGeneral4(String billCharGeneral4) {
		this.billCharGeneral4 = billCharGeneral4;
	}

	public String getBillCharGeneral5() {
		return this.billCharGeneral5;
	}

	public void setBillCharGeneral5(String billCharGeneral5) {
		this.billCharGeneral5 = billCharGeneral5;
	}

	public int getBillCharUpdatedby() {
		return this.billCharUpdatedby;
	}

	public void setBillCharUpdatedby(int billCharUpdatedby) {
		this.billCharUpdatedby = billCharUpdatedby;
	}


	public Set<BillingDetail> getBillingDetailCollection() {
		return this.billingDetailCollection;
	}

	public void setBillingDetailCollection(Set<BillingDetail> billingDetailCollection) {
		this.billingDetailCollection = billingDetailCollection;
	}

	public Set<BillingFooter> getBillingFooterCollection() {
		return this.billingFooterCollection;
	}

	public void setBillingFooterCollection(Set<BillingFooter> billingFooterCollection) {
		this.billingFooterCollection = billingFooterCollection;
	}

}
